//
//  CollectionViewCell.m
//  Study1
//
//  Created by Zeak on 2017/2/15.
//  Copyright © 2017年 Zeak. All rights reserved.
//

#import "CollectionViewCell.h"
#import "UIView+YZTCView.h"
#define SMALL_IMG_WIDTH ([UIScreen mainScreen].bounds.size.width-24) / 2
#define SMALL_IMG_HEIGHT 100

@interface CollectionViewCell()
{
    UIImageView *_imgView;
    UILabel *_labelBott;
    UILabel *_labelTop;
    
}
@end
@implementation CollectionViewCell

-(instancetype)initWithFrame:(CGRect)frame{
    if (self = [super initWithFrame:frame]) {
        _imgView = [[UIImageView alloc]initWithFrame: CGRectMake(0, 0, SMALL_IMG_WIDTH, SMALL_IMG_HEIGHT)];
        _imgView.image = [UIImage imageNamed:@"图层26"];
        _labelTop = [[UILabel alloc]initWithFrame:CGRectMake(_imgView.yzLeft, _imgView.yzBottom + 5, SMALL_IMG_WIDTH, 10)];
        _labelTop.text = @"产品经理入门指南";
        _labelTop.font = [UIFont systemFontOfSize:10];
        _labelBott = [[UILabel alloc]initWithFrame:CGRectMake(_labelTop.yzLeft, _labelTop.yzBottom + 4,_labelTop.yzWidth, _labelTop.yzHeight)];
        _labelBott.text = @"2017/01/06";
        _labelBott.font = [UIFont systemFontOfSize:10];

        
        [self.contentView addSubview:_imgView];
        [self.contentView addSubview:_labelTop];
        [self.contentView addSubview:_labelBott];
 
    }
    return self;
}

-(void)setDataDic:(NSDictionary *)dataDic{
    self.dataDic = dataDic;
    //具体设置图片和label
}
@end
